#ifndef iindexbuffer_h__
#define iindexbuffer_h__

namespace gecko
{

// forward declare types
class IRenderer;

// Abstract interface to platform specific index buffers.
class IIndexBuffer
{
public:
	// Initialise the vertex buffer.
    virtual bool Initialise(IRenderer *r, unsigned int indexCount, bool dynamic) = 0;

	// Lock the buffer prior to accessing index data.
    virtual bool Lock(unsigned int offset, unsigned int indexCount, unsigned short** indices) = 0;

	// Unlock the buffer after accessing index data.
    virtual bool Unlock() = 0;

	// Destroy the buffer and release resources.
    virtual bool Destroy() = 0;
};

}// namespace gecko

#endif // indexbuffer_h__
